
var masterList = "http://ggspamfree.googlecode.com/svn/trunk/stopwords.txt";
  
// Restore to saved value from localStorage.
function updateMasterList(cb) {
  var xhr = new XMLHttpRequest();
  xhr.open("GET", masterList, true);
  xhr.onreadystatechange = function() {
    if (xhr.readyState == 4) {
      localStorage["master"] = xhr.responseText.trim();
      localStorage["lastUpdate"] = (new Date).getTime();
      if (cb) cb(localStorage);
    }
  }
  xhr.send();
}
